pro*c ÀïÔõô½«select µÄ·µ»ØÄÚÈݸ³Öµ¸ø±äÁ¿
pro*c ÀïÔõô½«select µÄ·µ»ØÄÚÈݸ³Öµ¸ø±äÁ¿
EXEC SQL BEGIN DECLARE SECTION;
char CALLNO[30];
EXEC SQL END DECLARE SECTION;
EXEC SQL SELECT CALLNO INTO :CALLNO from out_call;
EXEC SQL COMMIT WORK RELEASE;
printf("CALLNO = %s\n intCALLNO = %d\n",CALLNO,intCALLNO);
´òÓ¡½á¹ûΪ¿Õ£¬ÊÇΪɶ£¿
Õâ¸ö²éѯÊÇÒ»¸ö½á¹û»¹ÊǶà¸ö½á¹û,Èç¹û¶à¸ö½á¹ûÇëʹÓÃÓαê,Èç¹ûÒ»¸ö½á¹ûÕâ¾ä»°Ã»Ê²Ã´ÎÊÌâ.
1.Êä³öΪһ¸ö½á¹ûµÄ
exec sql begin declare section;
CS_CHAR id[6];
CS_SMALLINT indic;
CS_CHAR pub_name[41];
exec sql end declare section;
exec sql select pub_id into :id indicator :indic
from titles where title
like "%Stress%";
if (indic == -1)
{
printf("\npub_id is null");
}
else
{
exec sql select pub_name into :pub_name
from publishers where pub_id = :id;
printf("\nPublisher: %s", pub_name);
}
2Êä³öΪ¶à¸ö½á¹ûµÄ
EXEC SQL DECLARE C1 CURSOR FOR
SELECT id, name, dept, job, years, salary, comm from staff;
EXEC SQL OPEN c1;
while (SQLCODE == 0)
{
EXEC SQL FETCH c1 INTO :id, :name, :dept, :job, :years, :salary, :comm;
if (SQLCODE == 0)
printf("%4d %12s %10d %10s %2d %8d %8d",
id, name, dept, job
Ïà¹ØÎÊ´ð£º
ËÄÜ°ïÎÒ°ÑÏÂÃæÕâЩ´úÂë¸Ä³ÉVBÐÎʽµÄ£¬¶àлÁË£¬¼±ÓÃ~~
#include "stdlib.h"
#include "math.h"
#include "stdio.h"
float objfx(float x[]);
void constraint(float x[],float g ......
ÔھƵê¹ÜÀíϵͳÖÐ,ÓÐÒ»¸ö¶ÔÄÚµÄϵͳ,¹©Ç°Ì¨·þÎñÔ±ºÍ¾ÀíʹÓÃ
»¹ÓÐÒ»¸ö¾ÍÊǶÔÍâ,Èÿͻ§¿ÉÒÔÔÚÍøÉÏÔ¤¶©·¿¼ä,
ËüÃÇÖ®¼äÊÇÔõôͨѶµÄ.?µ±ÎÒÌá½»Ô¤¶©·¿¼äÐÅÏ¢µÄʱºò,
ÔÚ¶ÔÄÚµÄϵͳÖÐ,ÈçºÎÖªµÀÎÒÒѾÌá½»ÁËÐÅÏ¢¹ýÈ¥.Ê¹Ç ......
ÏÖÓÐparadoxÊý¾Ý¿âʹÓÃBDEÇý¶¯£¬Äâ¸ÄΪC/S°æ£¬Ôö¼ÓÍøÂç¶ÁÈ¡Êý¾Ý¹¦ÄÜ¡£ÇëÄÄλ´óÏÀ£¬ÌṩԴÂë¡£
˵¾ä²»¿ÍÆøµÄ»°£¬ÓÃparadox×öC/SÊÇ×ÔÑ°ËÀ·¡£
»»Ò»¸öÍøÂçÊý¾Ý¿â
ÒòΪ²»Ï붯´óÊÖÊõ£¬½öÄܹ²Ïí¼¸¸öÎļþ¼´¿É¡£
Da ......
A±í ÓÐÁ½¸ö×Ö¶Î
id ΨһÊý×ÖÓò
InfoTxt text ÀàÐÍ
ÎÒÏÖÔÚÒª°Ñ id ²»ÊÇ14 µÄËùÓÐ InfoTxt×ֶΠÎı¾ºóÃæ ¶¼¼ÓÉÏ 'aaa'
°´ÏÂÃæÖ´ÐÐÏÂÀ´ Ö»Óбí×îºóÒ»ÐмÓÉÏÁË 'aaa' ......
ÎÒÃǵÄCÓïÑԿζ¼½áÁË¡£¸Ð¾õÀÏʦºÃÏñʲô¶¼Ã»½²ËƵġ£
ÒÔºó¾Í²»»á¿ª¿ÎÁË¡£ÎÒ»¹Ïë¼ÌÐøѧC£¬ÒªÔõôѧ²Å¸ßЧÇÒÇáËÉÄØ£¿
C¶ÔÊýѧҪÇóºÜ¸ßÂð£¿ÊýѧÀÏʦ½²¿Î×ÜÊÇ˵£º£º¡°Õâ¸ö¹«Ê½¶ÔÄãÃǼÆËã»úרҵµÄºÜÖØÒªµÄ£¡¡±¡£¿ÉÊÇÎÒà ......