Subject | Re: [IBO] using stored procedures. |
---|---|
Author | Helen Borrie |
Post date | 2001-09-11T13:01:30Z |
At 11:54 AM 11-09-01 +0000, you wrote:
create table Diary(
DiaryID integer not null,
YearStart date,
YearEnd date,
Description varchar(50),
constraint pk_diary primary key(DiaryID)
);
create table DiaryEntry(
DiaryEntryID integer not null,
DiaryID integer not null,
UserID integer not null,
DiaryDate date,
DiaryEntry blob sub_type 1,
SpecialEntry smallint,
constraint pk_DiaryEntry primary key(DiaryEntryID)
);
rgds,
Helen
All for Open and Open for All
InterBase Developer Initiative ยท http://www.interbase2000.org
_______________________________________________________
>My previous way of doing things having hit a brick wall I have triedWhy do you need to think "columns"?
>a new tack with no success.
>I want a table with a primary key integer
>And then about 200 columns or something that I can use as a diary.
create table Diary(
DiaryID integer not null,
YearStart date,
YearEnd date,
Description varchar(50),
constraint pk_diary primary key(DiaryID)
);
create table DiaryEntry(
DiaryEntryID integer not null,
DiaryID integer not null,
UserID integer not null,
DiaryDate date,
DiaryEntry blob sub_type 1,
SpecialEntry smallint,
constraint pk_DiaryEntry primary key(DiaryEntryID)
);
>I want to access it to put entries in or select entries from using a..just select the rows you want..
>stored proc.
>Is there any way to access columns in a stored proc other than byNo, you can only pass constants (or expressions that evaluate to constants) to SPs and variables can only represent constants.
>name?
>I can get the name out of RDB$Relation_Fields and into a varcharNot on, as above.
>variable but I can't use a variable as a field name.
>So try to use an array 200 smallintsRefer to TIB_ColumnArray.GetSlice and PutSlice. But you can't pass arrays to SPs, anyway.
>But cant get to put a value into an array slice. stored proc language
>seem to allow select from slice but not insert into slice .(I have
>examined the array sample program from Jason but does not seem to
>deal in slices!
>So I am only dealing with small integers so why not keep these asFirebird 1 has the SUBSTRING function; and there are enhancements to ib_udf.dll for substrings also. See the Language Enhancements and UDFs sections of the draft release notes at http://www.interbase2000.org/FB_1.0.0.0a_ReleaseNotes.htm
>chars in a VarChar(200) column. Yes but stored procedures have no
>string-handling capabilities. So I am no better off.
rgds,
Helen
All for Open and Open for All
InterBase Developer Initiative ยท http://www.interbase2000.org
_______________________________________________________