Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » U++ Library support » U++ SQL » sql using sqlexp
sql using sqlexp [message #52498] Fri, 11 October 2019 10:28 Go to next message
mtdew3q is currently offline  mtdew3q
Messages: 181
Registered: July 2010
Location: Upstate, NY (near Canada)
Experienced Member

Hi all-

I am trying in vain to get something to work right in sqlexp that is so easy in the sqlite console.

 sqlite> select event from DATES left outer join SCHEDULE on SCHEDULE.id = DATES.fk_schedule 
  


I left out the where clause on the console. I can do this in regular sqlite with calling execute with parameters but want to do it the sqlexp way.

If you can see why sqlexp keeps giving me an assert error, please let me know!

thnx for any help,
roboloki

 
eventGrid.Clear();
Sql sql;
sql * Select(fk_schedule(id,event))
.From(DATES).LeftJoinRef(SCHEDULE)
.On(fk_schedule.Of(DATES) == id.Of(SCHEDULE))
.Where(dt==Date(2019,9,28));
while (sql.Fetch()){
	eventGrid.Add(); }  


TABLE_(SCHEDULE)
INT_ (id) PRIMARY_KEY AUTO_INCREMENT
STRING_ (loc,55)
INT_ (fk_task)
STRING_ (event,100)
END_TABLE

TABLE_(DATES)
INT (id) PRIMARY_KEY AUTO_INCREMENT
INT_ (fk_schedule) REFERENCES (SCHEDULE)
DATE_ (dt)
TIME_ (tm)
DATE_ (dt2)
TIME_ (tm2)
DATE_ (rdate)
TIME_ (rtime)
END_TABLE
  


[Updated on: Fri, 11 October 2019 10:41]

Report message to a moderator

Re: sql using sqlexp [message #52499 is a reply to message #52498] Fri, 11 October 2019 11:44 Go to previous messageGo to next message
mtdew3q is currently offline  mtdew3q
Messages: 181
Registered: July 2010
Location: Upstate, NY (near Canada)
Experienced Member

Hi -

I tried changing the dates in the schema to INT_ . I still get the assert message.

I am headed for bed soon. Work in a couple of hours.

thnx.
Re: sql using sqlexp [message #52500 is a reply to message #52498] Fri, 11 October 2019 14:30 Go to previous messageGo to next message
mtdew3q is currently offline  mtdew3q
Messages: 181
Registered: July 2010
Location: Upstate, NY (near Canada)
Experienced Member

Hi,

I just thought of something that might
Fix it. I will look at it after work.
Thnx
Re: sql using sqlexp [message #52504 is a reply to message #52498] Sun, 13 October 2019 10:10 Go to previous message
mtdew3q is currently offline  mtdew3q
Messages: 181
Registered: July 2010
Location: Upstate, NY (near Canada)
Experienced Member

Hi all-

I think i figured out this problem.

My code wouldn't work, and I began to suspect that my computer got hacked.

I went and got nmap and ran a port scan. It came back with open ports!

So I decided to tie a rock to that computer and send it to the bottom of the river.

My new computer came back with nmap scans that are fine.

I knew that the sqlexp worked, and it defied logic why I couldn't get it running.

I could only run queries on one table at a time.

Back to sane test results I hope.

Have a cool rest of the weekend.

thanks,
roboloki
Previous Topic: PostgreSQL: JSONB Supporting by Upp
Next Topic: Missing SessionClose() in Sqlite3Session::Close()
Goto Forum:
  


Current Time: Thu Apr 18 10:40:40 CEST 2024

Total time taken to generate the page: 0.01330 seconds