Posts

https - How to specify CAFile path inline with the GIT command? -

i'm trying clone repository on https , reason local config says take cafile tries use value global config. local config: [http] sslcainfo = c:/../cacert-client.pem global config: [http] sslcainfo = /bin/curl-ca-bundle.crt when i'm executing clone command see instead of local value trying use global cafile value. how specify http.sslcainfo inline git clone command? c:/your/path/to/cacert-client.pem should work ,supposing ' /../ ' in question stands your/path/to (otherwise c:/../xx points non-existent path). if doesn't work, can try other syntax: git config http.sslcainfo /c/your/path/to/cacert-client.pem you can set git_curl_verbose 1 , see more of git using. getting path right (either git config , or environment variable git_ssl_cainfo ) bettern alternative: git_ssl_no_verify=true or git config --global http.sslverify false .

wolfram mathematica - ListPlot: individual point colors -

Image
i've got simple listplot like list2 = table[{x, sqrt[x]}, {x, 0, 100}]; now want color specific points red, every 5th point, tried mycolor[x_] /; mod[x, 5] == 0 = red; mycolor[_] = blue; now listplot[#, plotstyle -> absolutepointsize[3], colorfunction -> mycolor[#[[all, 1]], colorfunctionscaling -> false]] &[list2] doesnt work quite right, points still blue. wrong here? thanks, archi here easy way result you're after :- list2 = table[{x, sqrt[x]}, {x, 0, 100}]; mycolor[x_] := if[mod[x, 5] == 0, red, blue]; mycolors = mycolor /@ list2[[all, 1]]; listplot[list /@ list2, plotstyle -> map[{absolutepointsize[3], #} &, mycolors]] alternatively, colour function, rm -rf's answer on george's link :- list2 = table[{x, sqrt[x]}, {x, 0, 100}]; mycolor = function[{x, y}, if[mod[x, 5] == 0, red, blue]]; listlineplot[list2, plotstyle -> absolutepointsize[3], colorfunction -> mycolor, colorfunctionscaling -> false]...

sql - "Select count (*)" vs count of results from "Select 1" : which is more efficient way to get the rows count in DB2? -

i have 2 approaches count of rows in table in db2. 1 way is select count(*) foo col1 = val1; another way count results (number 1's list) retrived following query method in java code select 1 foo col1 = val1; here "list of number 1's" second query , size of list in java code count. can explain efficient way rows count ? select count faster - because database needs return single number rather potentially long list.

Get video object (or video id) from Facebook timeline post -

i'm trying facebook video object timeline post : i'm getting posts graph api /me/home i can photo object via returned object_id the problem there no object_id value video post type { "id": "750834774_10152138100019775", "from": { "id": "750834774", "name": "emilie volpi" }, "message": "haha le monde qui fait une analyse geopolitique de games of thrones^^ une bonne manière de se remettre à jour pour la nouvelle saison demain !!!!!", "picture": "https://fbexternal-a.akamaihd.net/safe_image.php?d=aqcclqte2bpmicry&w=130&h=130&url=http%3a%2f%2fs2.dmcdn.net%2fehfv4%2f526x297-mo8.jpg", "link": "http://www.dailymotion.com/video/x1lu3ke_game-of-thrones-comprendre-la-crise-a-westeros-en-4-minutes_news", "source": "http://www.dailymotion.com/swf/video/x1lu3ke?autoplay=1", ...

php - Why won't my prepared statement function properly? -

i have ajax call affiliated php handler has prepared statement in it. and won't work. no error caught. it stopped working when changed deprecated mysql_real_escape pdo prepared statememt. here code : $create_pdo=new pdo("mysql:host=$dbhost;dbname=$dbname",$dbuser,$dbpass); $statement=$create_pdo->prepare("insert registry (fname, lname, email, password, age, sex, city, timereg, frcode) values (:fname_received, :lname_received, :email_received, :password_received, :dob_received, :sex_received, :city_received, :timepassreg, :frcode)"); $statement->bindparam(':fname_received', $fname_received); $statement->bindparam(':lname_received', $lname_received); $statement->bindparam(':email_received', $email_received); $statement->bindparam(':password_received', $password_received); $statement->bindparam(':dob_received', $dob_received); $statement->bindparam(':sex_received', $sex_received); $st...

cluster computing - how to get the job id from qsub -

i using cluster. use qsub command distribute job, want can job id can monitor job. basically, want thing this: #!/bin/bash jobid=$( qsub job1 ) # monitoring base on $jobid i found page http://wiki.ibest.uidaho.edu/index.php/tutorial:_submitting_a_job_using_qsub , , talks variable pbs_jobid don't know how use it. know how it? (my solution jobid='qsub task | cut -d ' ' -f 3' ) qsub has predictable output. many automated submission systems (such grid interfaces) parse output qsub , looking jobid. an example of parsing available blahp project (european grid middleware). jobid=`${pbs_binpath}/qsub $bls_tmp_file` # actual submission ... # job id first numbers in string (slurm support) jobid=`echo $jobid | awk 'match($0,/[0-9]+/){print substr($0, rstart, rlength)}'` ( source ) this code has been used in production many years, , has worked qsub in both pbs, pbs pro, , slurm.

javascript - text into textbox when onclick -

i want create link if user presses edit link, text turn text box information still in user inputted? have following code: ( when press edit button 'text here' should turn textbox, doesn't notify code has gone wrong :) appreciated. <html> <head> <title>span text box - demo</title> <style type="text/css"> .replace { display:none; } </style> <script type="text/javascript"> function exchange(id){ var ie=document.all&&!window.opera? document.all : 0 var frmobj=ie? ie[id] : document.getelementbyid(id) var toobj=ie? ie[id+'b'] : document.getelementbyid(id+'b') toobj.style.width=frmobj.offsetwidth+7+'px' frmobj.style.display='none'; toobj.style.display='inline'; toobj.value=frmobj.innerhtml } </script> </head> <body> <p class="edit" onclick="exchange(item)">edit</p><input id="i...