Posts

oracle - Fetch all parents and children with "connect by" query for a particular input in sql -

i have table com_customer_mst, contains customer_id , parent_customer_id, need fetch parents , children particular customer_id input. 1 customer_id have single parent have multiple children. i have run query: select customer_id, customer_code, parent_customer_id sbsa_axia.com_customer_mst start customer_id = 154 connect prior customer_id = parent_customer_id; but giving children. customer_id parent_customer_id 61 12 18 12 111 12 250 12 14 15

ios - Why does navigation bar logo not display in master view -

Image
i'm writing ios 7/8 app , want display logo in center of nav bar. started master/detail project. added code change titleview logo (see following code). logo displays on detail page not on master page (the master page title displayed). i've tried putting code in navigation controller , view controller same result. there else needs set in storyboard or navcontroller code? var logo = uiimage(named: "logo_sm.png") var logoview = uiimageview(image: logo) self.navigationitem.titleview = logoview or in view controller var logo = uiimage(named: "logo_sm.png") var logoview = uiimageview(image: logo) self.navigationcontroller?.navigationitem.titleview = logoview edit found way make work. in uiviewcontroller changed code to: self.navigationitem.titleview = logoview this references view's navigationitem rather navigation controller's navigationitem. the first snippet works fine. think problem didn't add i...

mysql - How to set a variable in where clause of Select query in php -

while executing below query i'm not getting sucess value $name=qwe; $result = mysql_query("select *from user name = $name"); instead of above query if put below, can able appropriate ans: $result = mysql_query("select *from user name = 'qwe'"); can give solution first query?? close variable in quote , concatenate string query $name= "qwe"; $result = mysql_query("select *from user name = '".$name."'"); one more note please use mysqli security purposes. thanks

Android - Using SimpleCursorAdapter in AutoCompleteTextView gives CursorIndexOutofBoundsException when user selects 3rd suggestion onwards -

sorry mouthful of title, have cut down because exceeded 150 character limit. i have autocompletetextview (actv) , using simplecursoradapter since normal actv searches user input @ start of each substring (substring separated whitespaces) , not within substrings. example, having list adipose , bad wolf , searching ad show adipose , not bad wolf . made adapter shown below: //create actv here autocompletetextview search = (autocompletetextview) findviewbyid(r.id.actvcataloguesearch); search.setthreshold(1); string[] = { "name" }; int[] = { android.r.id.text1 }; simplecursoradapter cursoradapter = new simplecursoradapter(this, android.r.layout.simple_dropdown_item_1line, null, from, to, 0); cursoradapter.setstringconversioncolumn(1); filterqueryprovider provider = new filterqueryprovider(){ @override public cursor runquery(charsequence constraint) { // todo auto-generated method stub string constrain = (string) constraint; ...

Locale not set Programatically in Android 5.0 Lollipop -

my application set locale according selected language in application. kitkat code works fine. after update lollipop locale not set. here paste code set locale.. locale locale = new locale("de_de"); locale.setdefault(locale); configuration config = new configuration(); config.locale = locale; getbasecontext().getresources().updateconfiguration(config, null); you have change way of locale initialization. this: locale locale = new locale("de_de"); to this: string language = "de"; string country = "de"; locale locale = new locale(language , country); check out full response here https://stackoverflow.com/a/27490553/2659558 cheers!

How to Display a message box in excel vba when value in a cell exceeds another? -

i need message box appear when value in cell g27 exceeds value in cell k13 . require show cell g27 filled. have tried following macro, not working. private sub worksheet_change(byval target range) if range("g27") > range("k13") msgbox "error" end if end sub any highly appreciated! is trying? ( untested ) understood have code in sheet code area , not module :) private sub worksheet_change(byval target range) on error goto whoa application.enableevents = false if not intersect(target, range("g27")) nothing _ if range("g27").value > range("k13").value msgbox "error" letscontinue: application.enableevents = true exit sub whoa: msgbox err.description resume letscontinue end sub more worksheet_change here

c++ - Precompiled header error -

i have simple program 3 files(excluding precompiled header). have included precompiled header in .cpp files yet giving these 2 errors don't seem understand : 1>d:\practice\operatoroverloading\oopinheritance\oopinheritance\commisionemp.h(4): warning c4627: '#include ': skipped when looking precompiled header use 1> add directive 'stdafx.h' or rebuild precompiled header 1>d:\practice\operatoroverloading\oopinheritance\oopinheritance\commisionemp.h(35): fatal error c1010: unexpected end of file while looking precompiled header. did forget add '#include "stdafx.h"' source? ========== rebuild all: 0 succeeded, 1 failed, 0 skipped ========== here codes: oopinheritance.cpp // oopinheritance.cpp : defines entry point console application. // #include "stdafx.h" #include <iostream> #include <iomanip> #include "commisionemp.h" using namespace...