Yii Framework Forum: Ms Sql Custome Exception - Yii Framework Forum

Jump to content

Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

Ms Sql Custome Exception MS SQL Custome Exception like Raiserror('',16,1) Rate Topic: -----

#1 User is offline   sivavivekanantha 

  • Newbie
  • Yii
  • Group: Members
  • Posts: 1
  • Joined: 12-August 12

Posted 22 February 2013 - 04:25 AM

Hi

I'm new in YII. I have develop new app in linux cent os5.8. But I'm using MSSQL SERVER 2008-R2.

In my stored procedure return some message using Raiserror Command. I', using try Catch block. But yii CDbCommand.php file throw that message under PHP Warning. Please Help me

This MY Code

$sql = "[sp_Language] :Language_Code, :Language_Name, :Active, :Disp_Order, :Action ";
$command = $this->createCommand($sql);
$command->bindParam(":Language_Code", $languageCode, PDO::PARAM_INT);
$command->bindParam(":Language_Name", $language, PDO::PARAM_STR);
$command->bindParam(":Active", $active, PDO::PARAM_STR);
$command->bindParam(":Disp_Order", $displayOrder, PDO::PARAM_INT);
$command->bindParam(":Action", $action, PDO::PARAM_INT);
try {
$this->msg = '';
$command->execute();
}
catch(IOException $e) {
$this->msg=$command->errorInfo();
}

Thanks in Advance

Attached File(s)


0

Share this topic:


Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users