title: Unable to execute create stored procedure using Entity Framework 6 with npgsql in postgresql code first
body: <p>I am not able to create a stored procedure in npgsql using ASP.NET MVC 5.</p>
  
  <p>My migration code is:</p>
  
  <pre><code>CreateStoredProcedure("dbo.CustomerDetails_Insert",
                  p =&gt; new
                  {
                      p_chrv_ah_name = p.String(maxLength: 150),
                      p_chrv_ah_desig = p.String(maxLength: 50),
                      p_chrv_org_name = p.String(maxLength: 150),
                      p_chrv_org_phone = p.String(maxLength: 50),
                      p_chrv_org_email = p.String(maxLength: 150),
                      p_chrv_org_logo = p.String(maxLength: 150),
                      p_chrv_org_logo_path = p.String(maxLength: 255),
                      p_chrv_pwd = p.String(maxLength: 12),
                      p_tms_agreement_on = p.String(maxLength: 150),
                      p_chrv_agree_scan_copy = p.String(maxLength: 150),
                      p_chrv_agree_scan_copy_path = p.String(maxLength: 150),
                      p_chrv_ip_address = p.String(maxLength: 150)
                  },
                  body:
                  @"  DECLARE id character varying;
                      id= select 'cust' || EXTRACT (month from current_date)|| to_char(current_date,'yy')|| (select LPAD(CAST((select coalesce(max(int_slno),0)+1 from dbo.customer_details) as character varying),2,'0'))
                      INSERT INTO dbo.customer_details(chrv_cust_id,chrv_ah_name,chrv_ah_desig,chrv_org_name,chrv_org_phone,chrv_org_email,chrv_org_logo,chrv_org_logo_path,int_created_by,chrv_ip_address,chrv_pwd,tms_agreement_on,chrv_agree_scan_copy,chrv_agree_scan_copy_path)
                      VALUES(id,p_chrv_ah_name,p_chrv_ah_desig,p_chrv_org_name,p_chrv_org_phone,p_chrv_org_email,p_chrv_org_logo,p_chrv_org_logo_path,0,p_chrv_ip_address,p_chrv_pwd,p_tms_agreement_on,p_chrv_agree_scan_copy,p_chrv_agree_scan_copy_path);
                      "
                  );
  </code></pre>
  
  <p>but I get this error </p>
  
  <blockquote>
    <p>Unhandled MigrationOperation CreateProcedureOperation in NpgsqlMigrationSqlGenerator</p>
  </blockquote>
  
  <p>Does someone have the solution for this? If so, please post.</p>
  
  <p>Thanks in advance</p>