Diff in TD & Sqltalk

Discussion forum about all things SqlBase or SqlTalk
FRBhote
India
Posts: 2221
Joined: 09 Mar 2017, 05:32
Location: Hyderabad, India

Diff in TD & Sqltalk

Post by FRBhote » 28 Jun 2012, 07:24

When I do this in Sqltalk on ISLAND:

SELECT COMPANY_ID, COMPANY_ID FROM INVOICE INTO :nId, :nId ;

I get:

SELECT COMPANY_ID, COMPANY_ID FROM INVOICE INTO :nId, :nId
^
Error: 09912 PRS IVE INTO variable already exists
Reason: A duplicate INTO variable name is found.
Remedy: Check and change the duplicated INTO variable name.

But in TD, there is no error message.

Mike Vandine

Re: Diff in TD & Sqltalk

Post by Mike Vandine » 28 Jun 2012, 10:24

Hi Feroz,

As you probably know, SQLTalk has its own rules for things that sometimes don't parse as TD does. :)

If you read the SQLTalk manual, you will actually see that the bind variables are supposed to be limited to a colon and then numbers, i.e. :1, :2, :3

I'm sure that this will not accept duplicate bind variable names.

Cheers!

FRBhote
India
Posts: 2221
Joined: 09 Mar 2017, 05:32
Location: Hyderabad, India

Re: Diff in TD & Sqltalk

Post by FRBhote » 28 Jun 2012, 11:45

I observe that TD too replaces the bind vars with :1, :2 etc. :1 was :sRowid in the TD program.

008,28-JUN-12 09:11:55.28,LOCK HOLDER,VSL12,KUNAL,ACC-KUNAL,RL,30,0,0,Unknown,
UPDATE SYSADM.CASH_BOOK SET CB_PRINTS = 1 WHERE ROWID = :1

Let me see if TD parses this into :1, :2 or :1, :1.

By rights it should be the latter.

FRBhote
India
Posts: 2221
Joined: 09 Mar 2017, 05:32
Location: Hyderabad, India

Re: Diff in TD & Sqltalk

Post by FRBhote » 29 Jun 2012, 06:50

Unfortunately, the INTO variables don't get seen:

000,29-JUN-12 11:14:12.40,GLOBAL,ABC,8
008,29-JUN-12 11:19:34.67,LOCK HOLDER,ISLAND,SYSADM,frbctd,RL,15,0,0,Unknown,
update invoice set STATUS= 'x'
008,29-JUN-12 11:19:34.67,TIMEOUT,ISLAND,SYSADM,frbctd,RR,4,1461,2,S-Lock,
SELECT COMPANY_ID, COMPANY_ID FROM INVOICE

BTW, why is the default database of TD DEMO and not ISLAND?

Jeff Luther

Re: Diff in TD & Sqltalk

Post by Jeff Luther » 12 Jul 2012, 00:17

why is the default database of TD DEMO and not ISLAND?
Because 'DEMO' has been the default name from the old Gupta days in the 1980's and they never changed it. I think originally the default name for early SQLBase, they shipped a DEMO.DBS, and 'DEMO' stuck since it was first released in 1986. SQLWindows v1.0 (called the "Developer's Release") didn't get released until Sept, 1988.

FRBhote
India
Posts: 2221
Joined: 09 Mar 2017, 05:32
Location: Hyderabad, India

Re: Diff in TD & Sqltalk

Post by FRBhote » 12 Jul 2012, 05:52

Ok! I had assumed that ISLAND had been there forever.

Jeff Luther

Re: Diff in TD & Sqltalk

Post by Jeff Luther » 12 Jul 2012, 19:05

No, ISLAND came about when Gupta t/s or developers put together the Island demo/sample. I don't know exactly when, though; early Centura TD I would guess. I see an island sample in CTD v1.5, so back then.

Return to “SqlBase General Discussion”

Who is online

Users browsing this forum: [Ccbot] and 2 guests