Firebird SQL Development
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsDatabasesFirebird SQL Development

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
  #1  
Old June 6th, 2006, 05:27 AM
vendy vendy is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jun 2006
Posts: 3 vendy User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 1 h 14 m 43 sec
Reputation Power: 0
Dynamic sql error - execute statement

i'm frustated using "execute statement" in stored proc, i'm using interbase 6.5 (try it in fb 2.0 too but same result)..

i got this error message

invalid token
engine code : 335544569
engine message :

dynamic sql error
sql error code = -104
token unknown ..line..char..
statement

can anyone help me ???

Reply With Quote
  #2  
Old June 6th, 2006, 05:52 AM
pabloj's Avatar
pabloj pabloj is offline
Modding: Oracle MsSQL Firebird
Dev Shed God 6th Plane (7500 - 7999 posts)
 
Join Date: Jun 2001
Location: Outside US
Posts: 7,925 pabloj User rank is Captain (20000 - 30000 Reputation Level)pabloj User rank is Captain (20000 - 30000 Reputation Level)pabloj User rank is Captain (20000 - 30000 Reputation Level)pabloj User rank is Captain (20000 - 30000 Reputation Level)pabloj User rank is Captain (20000 - 30000 Reputation Level)pabloj User rank is Captain (20000 - 30000 Reputation Level)pabloj User rank is Captain (20000 - 30000 Reputation Level)pabloj User rank is Captain (20000 - 30000 Reputation Level)pabloj User rank is Captain (20000 - 30000 Reputation Level) 
Time spent in forums: 2 Months 3 Weeks 3 Days 20 h 9 m 23 sec
Reputation Power: 279
Some code could help ...

Reply With Quote
  #3  
Old June 6th, 2006, 08:24 AM
vendy vendy is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jun 2006
Posts: 3 vendy User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 1 h 14 m 43 sec
Reputation Power: 0
Quote:
Originally Posted by pabloj
Some code could help ...


CREATE PROCEDURE NEW_PROCEDURE
AS
begin
/* Procedure Text */
execute statement 'delete from saldobarang';

suspend;
end

error code return :

Invalid token.
Dynamic SQL Error.
SQL error code = -104.
Token unknown - line 5, char 9.
statement.

Reply With Quote
  #4  
Old June 8th, 2006, 05:26 AM
vendy vendy is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jun 2006
Posts: 3 vendy User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 1 h 14 m 43 sec
Reputation Power: 0
can any one help me ???
what's wrong with the code ??
is't a bug ?? or not yet supported at interbase 6.5
Comments on this post
pabloj disagrees!

Reply With Quote
  #5  
Old June 8th, 2006, 05:53 AM
pabloj's Avatar
pabloj pabloj is offline
Modding: Oracle MsSQL Firebird
Dev Shed God 6th Plane (7500 - 7999 posts)
 
Join Date: Jun 2001
Location: Outside US
Posts: 7,925 pabloj User rank is Captain (20000 - 30000 Reputation Level)pabloj User rank is Captain (20000 - 30000 Reputation Level)pabloj User rank is Captain (20000 - 30000 Reputation Level)pabloj User rank is Captain (20000 - 30000 Reputation Level)pabloj User rank is Captain (20000 - 30000 Reputation Level)pabloj User rank is Captain (20000 - 30000 Reputation Level)pabloj User rank is Captain (20000 - 30000 Reputation Level)pabloj User rank is Captain (20000 - 30000 Reputation Level)pabloj User rank is Captain (20000 - 30000 Reputation Level) 
Time spent in forums: 2 Months 3 Weeks 3 Days 20 h 9 m 23 sec
Reputation Power: 279
Please consider that:

1. We are here to help at our discretion, so please refrain from "bumping" threads or sending private messages or emails asking for help

2. We might not have the same software version as you do (I'm on Firebird 2 for example)

3. There is no need for a stored proc with execute statement, which is aimed at using dynamic sql, to issue a delete

4. I have something like yours running perfectly in Firebird 2

5. Interbase 6.5 is a commercial product, you should check with Borland

Regards

Reply With Quote
  #6  
Old June 8th, 2006, 06:06 AM
pabloj's Avatar
pabloj pabloj is offline
Modding: Oracle MsSQL Firebird
Dev Shed God 6th Plane (7500 - 7999 posts)
 
Join Date: Jun 2001
Location: Outside US
Posts: 7,925 pabloj User rank is Captain (20000 - 30000 Reputation Level)pabloj User rank is Captain (20000 - 30000 Reputation Level)pabloj User rank is Captain (20000 - 30000 Reputation Level)pabloj User rank is Captain (20000 - 30000 Reputation Level)pabloj User rank is Captain (20000 - 30000 Reputation Level)pabloj User rank is Captain (20000 - 30000 Reputation Level)pabloj User rank is Captain (20000 - 30000 Reputation Level)pabloj User rank is Captain (20000 - 30000 Reputation Level)pabloj User rank is Captain (20000 - 30000 Reputation Level) 
Time spent in forums: 2 Months 3 Weeks 3 Days 20 h 9 m 23 sec
Reputation Power: 279
sql Code:
Original - sql Code
  1. SET TERM ^ ;
  2.  
  3. CREATE PROCEDURE cleaner
  4. AS
  5.  
  6. BEGIN
  7.   EXECUTE STATEMENT 'DELETE FROM TEST_HEADER';
  8. END
  9. ^
  10.  
  11. SET TERM ; ^
Example working on Firebird 2.0

Reply With Quote
Reply

Viewing: Dev Shed ForumsDatabasesFirebird SQL Development > Dynamic sql error - execute statement


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 3 hosted by Hostway
Stay green...Green IT